package com.loyal.impl;

import android.view.View;
import android.view.ViewGroup;

import androidx.annotation.LayoutRes;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import java.util.List;

public interface AdapterImpl<T> {

    void addCallback(@Nullable AdapterCallback callback);

    /*刷新列表*/
    void notifyList(@Nullable List<T> arrList);

    /*空数据刷新列表*/
    void notifyEmpty();

    /*赋值，不刷新列表*/
    void changedList(@Nullable List<T> arrList);

    @NonNull
    List<T> getList();

    T getItem(int position);

    @LayoutRes
    int adapterLayout();

    View getConvertView(ViewGroup parent);

    @NonNull
    String replaceText(@Nullable CharSequence sequence);

    @NonNull
    String subEndTime(@Nullable CharSequence time);

}
